package top.oneit.jdownload.stages.dialog;

import javafx.scene.image.Image;
import javafx.stage.Modality;
import top.oneit.jdownload.data.entity.DownloadHistory;
import top.oneit.jdownload.stages.BaseStage;

import java.util.List;
import java.util.Map;

/**
 * @author lingkang
 * @date 2021/11/10
 * 保存目录
 */
public class SelectSavePosition extends BaseStage {

    public Map<String, List<String>> responseHeader;
    public DownloadHistory history;

    public SelectSavePosition(Map<String, List<String>> responseHeader,DownloadHistory history) {
        this.responseHeader = responseHeader;
        this.history=history;
        init();
    }

    public SelectSavePosition() {
        init();
    }

    private void init() {
        // 加载 xml
        setXML("/fxml/dialog/select-save-position.fxml");
        getIcons().add(new Image("/assets/茶壶.png"));
        setTitle("创建下载任务");
        // 模态窗口
        initModality(Modality.APPLICATION_MODAL);
        show();
    }

}
